Optimal. Leaf size=49 \[ \frac {\cos (c+d x)}{a^3 d}-\frac {\cot (c+d x)}{a^3 d}+\frac {3 \tanh ^{-1}(\cos (c+d x))}{a^3 d}+\frac {3 x}{a^3} \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.16, antiderivative size = 49, normalized size of antiderivative = 1.00, number of steps used = 7, number of rules used = 6, integrand size = 29, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.207, Rules used = {2869, 2757, 3770, 3767, 8, 2638} \[ \frac {\cos (c+d x)}{a^3 d}-\frac {\cot (c+d x)}{a^3 d}+\frac {3 \tanh ^{-1}(\cos (c+d x))}{a^3 d}+\frac {3 x}{a^3} \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 8
Rule 2638
Rule 2757
Rule 2869
Rule 3767
Rule 3770
Rubi steps
\begin {align*} \int \frac {\cos ^4(c+d x) \cot ^2(c+d x)}{(a+a \sin (c+d x))^3} \, dx &=\frac {\int \csc ^2(c+d x) (a-a \sin (c+d x))^3 \, dx}{a^6}\\ &=\frac {\int \left (3 a^3-3 a^3 \csc (c+d x)+a^3 \csc ^2(c+d x)-a^3 \sin (c+d x)\right ) \, dx}{a^6}\\ &=\frac {3 x}{a^3}+\frac {\int \csc ^2(c+d x) \, dx}{a^3}-\frac {\int \sin (c+d x) \, dx}{a^3}-\frac {3 \int \csc (c+d x) \, dx}{a^3}\\ &=\frac {3 x}{a^3}+\frac {3 \tanh ^{-1}(\cos (c+d x))}{a^3 d}+\frac {\cos (c+d x)}{a^3 d}-\frac {\operatorname {Subst}(\int 1 \, dx,x,\cot (c+d x))}{a^3 d}\\ &=\frac {3 x}{a^3}+\frac {3 \tanh ^{-1}(\cos (c+d x))}{a^3 d}+\frac {\cos (c+d x)}{a^3 d}-\frac {\cot (c+d x)}{a^3 d}\\ \end {align*}
________________________________________________________________________________________
Mathematica [B] time = 0.50, size = 106, normalized size = 2.16 \[ \frac {\left (\sin \left (\frac {1}{2} (c+d x)\right )+\cos \left (\frac {1}{2} (c+d x)\right )\right )^6 \left (6 (c+d x)+2 \cos (c+d x)+\tan \left (\frac {1}{2} (c+d x)\right )-\cot \left (\frac {1}{2} (c+d x)\right )-6 \log \left (\sin \left (\frac {1}{2} (c+d x)\right )\right )+6 \log \left (\cos \left (\frac {1}{2} (c+d x)\right )\right )\right )}{2 d (a \sin (c+d x)+a)^3} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
fricas [A] time = 0.69, size = 82, normalized size = 1.67 \[ \frac {2 \, {\left (3 \, d x + \cos \left (d x + c\right )\right )} \sin \left (d x + c\right ) + 3 \, \log \left (\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right ) \sin \left (d x + c\right ) - 3 \, \log \left (-\frac {1}{2} \, \cos \left (d x + c\right ) + \frac {1}{2}\right ) \sin \left (d x + c\right ) - 2 \, \cos \left (d x + c\right )}{2 \, a^{3} d \sin \left (d x + c\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
giac [B] time = 0.21, size = 111, normalized size = 2.27 \[ \frac {\frac {6 \, {\left (d x + c\right )}}{a^{3}} - \frac {6 \, \log \left ({\left | \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) \right |}\right )}{a^{3}} + \frac {\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )}{a^{3}} + \frac {2 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} - \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{2} + 6 \, \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right ) - 1}{{\left (\tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )^{3} + \tan \left (\frac {1}{2} \, d x + \frac {1}{2} \, c\right )\right )} a^{3}}}{2 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maple [A] time = 0.66, size = 97, normalized size = 1.98 \[ \frac {\tan \left (\frac {d x}{2}+\frac {c}{2}\right )}{2 d \,a^{3}}+\frac {2}{a^{3} d \left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}+\frac {6 \arctan \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{a^{3} d}-\frac {1}{2 d \,a^{3} \tan \left (\frac {d x}{2}+\frac {c}{2}\right )}-\frac {3 \ln \left (\tan \left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{a^{3} d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
maxima [B] time = 0.43, size = 158, normalized size = 3.22 \[ \frac {\frac {\frac {4 \, \sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} - \frac {\sin \left (d x + c\right )^{2}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{2}} - 1}{\frac {a^{3} \sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1} + \frac {a^{3} \sin \left (d x + c\right )^{3}}{{\left (\cos \left (d x + c\right ) + 1\right )}^{3}}} + \frac {12 \, \arctan \left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1}\right )}{a^{3}} - \frac {6 \, \log \left (\frac {\sin \left (d x + c\right )}{\cos \left (d x + c\right ) + 1}\right )}{a^{3}} + \frac {\sin \left (d x + c\right )}{a^{3} {\left (\cos \left (d x + c\right ) + 1\right )}}}{2 \, d} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
mupad [B] time = 9.48, size = 151, normalized size = 3.08 \[ \frac {\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{2\,a^3\,d}-\frac {3\,\ln \left (\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )}{a^3\,d}-\frac {6\,\mathrm {atan}\left (\frac {36}{36\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )+36}-\frac {36\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}{36\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )+36}\right )}{a^3\,d}-\frac {{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^2-4\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )+1}{d\,\left (2\,a^3\,{\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )}^3+2\,a^3\,\mathrm {tan}\left (\frac {c}{2}+\frac {d\,x}{2}\right )\right )} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
sympy [F(-1)] time = 0.00, size = 0, normalized size = 0.00 \[ \text {Timed out} \]
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________